home *** CD-ROM | disk | FTP | other *** search
- Path: news.cern.ch!danpop
- From: danpop@mail.cern.ch (Dan Pop)
- Newsgroups: comp.lang.c
- Subject: Re: Defeat password by C
- Date: 19 Apr 96 15:34:55 GMT
- Organization: CERN European Lab for Particle Physics
- Message-ID: <danpop.829928095@news.cern.ch>
- References: <4l4cns$gs0@usenetp1.news.prodigy.com> <4l4n57INNb5g@keats.ugrad.cs.ubc.ca> <4l8832$9jb@abel.cc.sunysb.edu>
- NNTP-Posting-Host: hpplus01.cern.ch
- Mime-Version: 1.0
- Content-Type: text/plain; charset=US-ASCII
- Content-Transfer-Encoding: 7bit
- X-Newsreader: NN version 6.5.0 #18 (NOV)
-
- In <4l8832$9jb@abel.cc.sunysb.edu> dkat@psych1.psy.sunysb.edu (DK) writes:
-
- >c2a192@ugrad.cs.ubc.ca (Kazimir Kylheku) wrote:
- >
- >>In article <4l4cns$gs0@usenetp1.news.prodigy.com>,
- >>Bubba Meigs <VRLL67A@prodigy.com> wrote:
- >>>I am a student who trying to learn how to program C++.
- >>>I just wonder if anyone know how to write a program by C++ to break the
- >>>password.
- >
- >>main()
- >>{
- >> char pass[] = "mylamepassword";
- >
- >> pass[8] = 0;
-
- >/* do you mean pass[8] = '\0'; ?
-
- I'm afraid I'm completely clueless here. Pray tell, what is the difference
- between 0 and '\0' in C (not C++)???
-
- >if so why?
-
- To break the password, obviously :-) The joke makes sense even without the
- Unix-specific pun. That is, assuming a non-humour impaired reader.
-
- >if not what does this do?
-
- See above.
-
- >DK - opps - this is a reference to c++ which I know not. I
- >thought we were doing good old C*.
-
- I'm afraid you were wrong. We were doing the good old C, not the good old
- C*.
-
- >Still the questions remain and are sincere DK*/
-
- Sincerity is not a good substitute for either C knowledge (see the 0 vs '\0'
- bit) or sense of humour.
-
- Dan :-)
- --
- Dan Pop
- CERN, CN Division
- Email: danpop@mail.cern.ch
- Mail: CERN - PPE, Bat. 31 R-004, CH-1211 Geneve 23, Switzerland
-